package com.shz.config;

import com.shz.functions.LocationNameFunction;
import org.springframework.ai.chat.client.ChatClient;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import org.springframework.context.annotation.Description;

import java.util.function.Function;

@Configuration
public class AIconfig  {
    @Bean
    ChatClient chatClient(ChatClient.Builder builder){
        return builder.defaultSystem("你现在是一个党建服务ai管家").build();
    }
    @Bean
    @Description("某个地方有多少什么名字的人")
    public Function<LocationNameFunction.Request,LocationNameFunction.Response> locationNameFunction(){
        return new LocationNameFunction();
    }


}
